package cn.wubo.dynamic.schedule.controller;

import cn.wubo.dynamic.schedule.entity.TaskRecord;
import lombok.Data;
import lombok.EqualsAndHashCode;

@EqualsAndHashCode(callSuper = true)
@Data
public class TaskRecordVO extends TaskRecord {
    private String status;

    public TaskRecordVO(TaskRecord taskRecord, String status) {
        this.setId(taskRecord.getId());
        this.setMemo(taskRecord.getMemo());
        this.setCron(taskRecord.getCron());
        this.setMethodName(taskRecord.getMethodName());
        this.setGroovyContext(taskRecord.getGroovyContext());
        this.setIsStartCron(taskRecord.getIsStartCron());
        this.setIsStartRun(taskRecord.getIsStartRun());
        this.status = status;
    }
}
